/**
 * Created with JetBrains PhpStorm.
 * User: Administrator
 * Date: 13-9-30
 * Time: 下午2:29
 * To change this template use File | Settings | File Templates.
 */
//selectClass 首选option targetClass 被选的option的value  selects ：options
function selectClass(targetClass,selects){
    var targetClass = document.getElementById(targetClass);
    var t_c = targetClass.value;
    var selects = document.getElementsByClassName(selects);
    for(var i=0;i < selects.length;i++){
        if(selects[i].value == t_c){
            selects[i].selected = "selected";
        }
    }
}